package utils

import (
	"crypto/md5"
	"encoding/hex"
	uuid "github.com/satori/go.uuid"
	"strings"
)

func GenerateUuid() string {
	return strings.ReplaceAll(uuid.NewV4().String(), "-", "")
}

func GetMd5(src string) string {
	h := md5.New()
	h.Write([]byte(src))
	return hex.EncodeToString(h.Sum(nil))
}
